<html>
<head><meta charset="utf-8"><title>some · t-compiler/rust-analyzer · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/index.html">t-compiler/rust-analyzer</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/some.html">some</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="216011675"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/some/near/216011675" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> pksunkara <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/some.html#216011675">(Nov 08 2020 at 15:33)</a>:</h4>
<p>Do we have a <code>Some(|)</code> wrapper that behaves like the current <code>.ok</code> and <code>.cl</code> snippets?</p>



<a name="216013003"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/some/near/216013003" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Laurențiu <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/some.html#216013003">(Nov 08 2020 at 16:09)</a>:</h4>
<p>I don't think so, but there might be a "wrap in <code>Result</code>" (<code>Option</code> too?) assist</p>



<a name="216017465"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/some/near/216017465" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> pksunkara <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/some.html#216017465">(Nov 08 2020 at 17:52)</a>:</h4>
<p>Yeah, but that's an assist. But <code>.ok</code> and <code>.cl</code> and <code>.match</code> are auto completions. If you could point me to the correct place, I can add <code>.some</code> too</p>



<a name="216018045"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/some/near/216018045" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Lukas Wirth <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/some.html#216018045">(Nov 08 2020 at 18:07)</a>:</h4>
<p><a href="https://github.com/rust-analyzer/rust-analyzer/blob/945900bdbf5423fdfb8542901dfb813c2ec32e09/crates/completion/src/completions/postfix.rs#L180">this</a> is where the ok completion is defined</p>



<a name="216018769"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/some/near/216018769" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> pksunkara <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/some.html#216018769">(Nov 08 2020 at 18:24)</a>:</h4>
<p>Thanks</p>



<a name="216019525"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/some/near/216019525" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> pksunkara <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/some.html#216019525">(Nov 08 2020 at 18:44)</a>:</h4>
<p><a href="https://github.com/rust-analyzer/rust-analyzer/pull/6500">https://github.com/rust-analyzer/rust-analyzer/pull/6500</a></p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>